package top.kaoshanji.r1ch06a;

import org.junit.Assert;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;
import org.testng.annotations.BeforeClass;
import org.testng.annotations.Test;

/**
 * @author kaoshanji
 * ^_^
 * create time 2025/5/6 19:06
 */
public class CustomerEditorTest {

    public ApplicationContext context;

    @BeforeClass
    public void setUp() {
        context = new ClassPathXmlApplicationContext("r1ch06a/beans.xml");
    }

    /**
     * 代码清单test-r1ch06a-01：测试一下自定义编辑器
     */
    @Test
    public void testCustomerCarEditor() {
        Boss boss = (Boss) context.getBean("boss");

        Assert.assertNotNull(boss);

        System.out.println(boss);

    }

}
